package com.guigu.p1;

import java.util.Objects;

public class Customer {
    private String name;
    private String age;
    private String gender;
    private String phone;
    private String email;

    public Customer() {
    }

    public Customer(String name, String age, String gender, String phone, String email) {
        this.name = name;
        this.age = age;
        this.gender = gender;
        this.phone = phone;
        this.email = email;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAge() {
        return age;
    }

    public void setAge(String age) {
        this.age = age;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    @Override
    public String toString() {
        return name+"\t\t"+age+"\t\t"+gender+"\t\t"+phone+"\t\t\t"+email;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Customer customer = (Customer) o;
        return Objects.equals(name, customer.name) &&
                Objects.equals(age, customer.age) &&
                Objects.equals(gender, customer.gender) &&
                Objects.equals(phone, customer.phone) &&
                Objects.equals(email, customer.email);
    }

   /* @Override
    public int hashCode() {

        return Objects.hash(name, age, gender, phone, email);
    }*/
}
